package com.uw.scenic.feigin;


/**
 * 调用用户远程调用
 */

import com.uw.scenic.constant.ServiceConstant;
import com.uw.scenic.feigin.hystrix.TestUserClientHystrix;
import com.uw.scenic.vo.R;
import com.uw.scenic.vo.SysUserVO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;

/**
 * 优惠券模板微服务feign定义
 *
 * 方式一、此种方式用于远程调用熔断机制，前期如果业务偏多，可以暂不使用
 * @FeignClient(value = ServiceConstant.EUREKA_CLIENT_SCENIC_USER,fallback = TestUserClientHystrix.class)
 *
 * 方式二、 普通调用，没有熔断机制
 * @FeignClient(value = ServiceConstant.EUREKA_CLIENT_SCENIC_USER)
 *
 */
//@FeignClient(value = ServiceConstant.EUREKA_CLIENT_SCENIC_USER)
@FeignClient(value = ServiceConstant.EUREKA_CLIENT_SCENIC_USER,fallback = TestUserClientHystrix.class)
public interface TestUserClient {

    @GetMapping(ServiceConstant.EUREKA_CLIENT_SCENIC_USER_CONTEXT_PATH+"/testUser/get")
    public R<SysUserVO> getById();

    @GetMapping(ServiceConstant.EUREKA_CLIENT_SCENIC_USER_CONTEXT_PATH+"/testUser/get2")
    public R<SysUserVO> getById2();

    @GetMapping(ServiceConstant.EUREKA_CLIENT_SCENIC_USER_CONTEXT_PATH+"/testUser/get3")
    SysUserVO getById3();

    @GetMapping(ServiceConstant.EUREKA_CLIENT_SCENIC_USER_CONTEXT_PATH+"/testUser/get4")
    SysUserVO getById4();
}
